package com.training.thread.section01;

public class MyThread extends Thread {
	@Override
	public void run() {
		for(int i = 0 ; i < 10 ; i++) {
			System.out.println(this.getName()+":"+i);
			try {
				sleep(200);
			} catch (InterruptedException e) {
				e.printStackTrace();
			}
		}
	}
	public static void main(String[] args) {
		Thread t1 = new MyThread();
		Thread t2 = new MyThread();
		
		t1.start();//让线程进入就绪状态
		t2.start();
	}
}
